package com.ldzy.pojo;

public enum ResultCode {
    SUCCESS(100,"操作成功"),
    OK_REGISITER(101,"注册成功"),

    ERROR(200,"操作失败"),
    NOT_ROLE(201,"无角色"),
    NOT_LOGIN(202,"未登录"),
    NOT_USER(203,"不存在该用户"),
    ERROR_NAME_PASSWORD(204,"用户名不对或者密码不对"),
    NOT_PASSWORD(205,"密码不正确"),
    NOT_ACTIVE(206,"用户没有激活"),
    ERROR_DB(207,"数据库异常"),
    ERROR_USERNAME(208,"用户名重复，请重新输入其他用户名！"),
    ERROR_EMAIL_ADDRESS(209,"邮箱地址格式不合格，请重新输入"),
    ERROR_EMAIL_SEND(210,"发送失败"),
    ERROR_PARAMS(211,"请求参数格式不对或类型不对或缺失"),
    ERROR_USER_DISABLED(31,"用户状态禁用");
    private int code;
    private String desc;
    ResultCode(int code,String desc){
        this.code = code;
        this.desc = desc;
    }
    public int getCode(){
        return code;
    }
    public String getDesc(){
        return desc;
    }
}
